debian/tests/test-local-pull: Run the unreliable test separately, repeated 3 times...
authorSimon McVittie <smcv@debian.org>
Tue, 17 Jan 2017 10:36:14 +0000 (10:36 +0000)
committerSimon McVittie <smcv@debian.org>
Thu, 19 Jan 2017 12:07:39 +0000 (12:07 +0000)
debian/changelog
debian/tests/control
debian/tests/test-local-pull [new file with mode: 0755]

index bdbcba796e0b61760a6468d5b40f87beac0cf349..77ea701769bec0930d9311829ca42016441b0664 100644 (file)
@@ -7,6 +7,9 @@ ostree (2016.15-3) UNRELEASED; urgency=medium
       the script but do not attempt to run it
   * debian/tests/gnome-desktop-testing: Skip test-local-pull.sh.test
     which suffers from a known bug (#842606)
+  * debian/tests/gnome-desktop-testing: Fail if no tests were found
+    - debian/tests/test-local-pull: Run the unreliable test separately,
+      repeated 3 times to assess how often it fails
 
  -- Simon McVittie <smcv@debian.org>  Sun, 15 Jan 2017 14:37:12 +0000
 
index 88ffde7f521cb59890ff1513a9c9e55dabe0cc93..5c627361429f5a75746bae57fef3354566deb859 100644 (file)
@@ -1,4 +1,4 @@
-Tests: gnome-desktop-testing
+Tests: gnome-desktop-testing, test-local-pull
 Depends: gnome-desktop-testing, ostree-tests
 
 Tests: build
diff --git a/debian/tests/test-local-pull b/debian/tests/test-local-pull
new file mode 100755 (executable)
index 0000000..36f64d8
--- /dev/null
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+set -e
+exec 2>&1
+
+N=3
+passed=0
+
+for i in `seq 1 $N`; do
+       if gnome-desktop-testing-runner ostree/test-local-pull.sh.test; then
+               passed=$(( $passed + 1))
+       fi
+done
+
+echo "test-local-pull: passed $passed/$N attempts"
+
+if [ "$passed" -ne "$N" ]; then
+       exit 1
+fi